package com.wyg.command;

/**
 * @description:
 * @author: WYG
 * @time: 2021/3/30 8:46
 */

public class LightOnCommand implements Command{
    private Light light;
    public LightOnCommand(Light light) {
        this.light = light;
    }
    @Override
    public void execute() {
        light.on();
    }

    @Override
    public void undo() {
        light.off();
    }
}
